<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="jt" uri="/kingschan.com"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title>JeasyTag</title>
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">	
  </head>
  
  <body>
  皮肤:
  <jt:ComboBoxTag id="selectbox" width="120" onSelect="changeskin(record);">
  <option value="default">default</option>
  <option value="sunny">sunny</option>
  <option value="cupertino">cupertino</option>
  <option value="dark-hive">dark-hive</option>
  <option value="pepper-grinder">pepper-grinder</option>
  <option value="black">black</option>
  <option value="bootstrap">bootstrap</option>
  <option value="cupertino">cupertino</option>
  <option value="gray">gray</option>
  <option value="metro">metro</option>
  <option value="metro-blue">metro-blue</option>
  <option value="metro-gray">metro-gray</option>
  <option value="metro-green">metro-green</option>
  <option value="metro-orange">metro-orange</option>
  <option value="metro-red">metro-red</option>
  <option value="pepper-grinder">pepper-grinder</option>  
  </jt:ComboBoxTag>
  
  
  <jt:ComboBoxTag id="tdcombox"  width="200"  value="输入关键字进行查询" hasDownArrow="true">
  </jt:ComboBoxTag>
  
  <input type="button" onclick="test();" value="test"/>
      <jt:GridTag		
		id="testgrid"
		title="数据列表"
		height="400"
		toolbar="auto"		
		pagination="true"
		rownumbers="true"
		remoteSort="true"	
		>		
		<jt:ColumnTag checkbox="true" field="CODE" width="120" title=""></jt:ColumnTag>
		<jt:ColumnTag  field="NAME" title="名称" width="120" editor="{type:'combobox',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="PARENTCODE" title="父代码" width="120" editor="{type:'text',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="EXPLAIN" title="说明" width="240" editor="{type:'text',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="SETER" title="创建者" width="80" editor="{type:'text',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="SETDATE" title="创建者时间" width="120" editor="{type:'datebox',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="PROFESSIONCLASS" title="技职类别" width="120" editor="{type:'text',options:{required:true}}"></jt:ColumnTag>
		<jt:ColumnTag  field="TECHSERIES" title="技术系列" width="120" editor="{type:'text',options:{required:true}}"></jt:ColumnTag>
			<jt:DIYTag classname=" com.kingschan.easytag.test.DIYTagTest" method="test"></jt:DIYTag>
			<jt:SQLTag	DBtype="ORACLE" >
			SELECT CODE,NAME,PARENTCODE,EXPLAIN,SETER,SETDATE,PROFESSIONCLASS,TECHSERIES from p_tech_duty order by NAME
			</jt:SQLTag>
			<jt:SearchBoxTag id="gsearch"></jt:SearchBoxTag>						
		</jt:GridTag>
 
  	<div id="tooldiv">
  		<input>
  	</div>
 
  
		
		<h1>combobox </h1>
		<jt:ComboBoxTag id="tcombox" textField="TEXT" valueField="VALUE" url="auto" width="200" editable="false" value="管理" separator="," multiple="true">
		  <jt:SQLTag DBtype="ORACLE">
		  		select NAME as text,NAME as value from  p_tech_duty
		  </jt:SQLTag>
  		</jt:ComboBoxTag>
  		
  </body>
  <jt:EasyTagHead skin="default" />
</html>
<script>
function changeskin(record){
	$("#jeasytag-skin").attr("href","<%=request.getContextPath()%>/jeasytag_resource/easyui/themes/"+record.value+"/easyui.css");
}

function test(){	
	var data=$('#testgrid').datagrid('getRows');
	alert(Serialize(data));
}
</script>